package com.beamfield.dao.sys;

import com.beamfield.model.ProjectDetailSupplies;
import com.beamfield.modelVo.ProductSuppliesVo;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public interface ProjectDetailSuppliesMapper {
    int deleteByPrimaryKey(Long project_detail_supplies_id);

    int insert(ProjectDetailSupplies record);

    int insertSelective(ProjectDetailSupplies record);

    ProjectDetailSupplies selectByPrimaryKey(Long project_detail_supplies_id);

    int updateByPrimaryKeySelective(ProjectDetailSupplies record);

    int updateByPrimaryKey(ProjectDetailSupplies record);

    List<ProductSuppliesVo> selectByProjectDetailId(@Param("projectId") String projectId,
                                                    @Param("productId") String productId,
                                                    @Param("projectDetailId") String projectDetailId,
                                                    @Param("offset") String offset,
                                                    @Param("limit") String limit);

    int deleteByProjectId(@Param("projectId") Long projectId,@Param("beamId") Long beamId);

    long countByProjectDetailId(@Param("projectId") String projectId,
                                @Param("productId") String productId,
                                @Param("projectDetailId") String projectDetailId);

    int deleteByProjectDetailId(@Param("projectDetailId") Long projectDetailId);

    List<ProjectDetailSupplies> selectByPDId(@Param("projectDetailId") Long projectDetailId);

    ProjectDetailSupplies selectBySuppliesAndPDId(@Param("suppliesId") String suppliesId,@Param("projectDetailId") Long projectDetailId);
}
